#include <ballade/util.h>
#include <string>

#include "func_test.h"

namespace Ballade
{
	
	namespace Util
	{
		using std::string;
		
		CPPUNIT_TEST_SUITE_REGISTRATION(FuncTest);
		
		void FuncTest::testRepr()
		{
			string msg("abcdefg");
			char *buf = new char[msg.length() * 4];
			memset(buf, 0x00, msg.length() * 4);
			repr(buf, msg.c_str(), msg.length());
			CPPUNIT_ASSERT(memcmp("0x610x620x630x640x650x660x67", buf, 7) == 0);
		}
		
		void FuncTest::testHtonf()
		{
			
		}
		
		void FuncTest::testNtohf()
		{
			
		}
	}
}

